package com.wjm.blog.core.swagger;

import lombok.Data;
import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import springfox.documentation.service.Contact;
import springfox.documentation.service.VendorExtension;

import java.util.List;

/**
 * Swagger配置
 *
 * @author jiyuan
 * @version 1.0
 * @date 2020/4/20 11:44
 */
@ConditionalOnExpression("${platform.xian.swagger.enable:true}")
@ConfigurationProperties(prefix = "swagger")
@Configuration
@Data
public class SwaggerProperties {

    /**
     * 版本号
     */
    private String version = "v1.0.0";

    /**
     * 标题
     */
    private String title = "绛门科技接口文档";

    /**
     * 描述，联系电话：025-52898928
     */
    private String description = "绛门科技接口文档";

    private String termsOfServiceUrl;

    private String license;

    private String licenseUrl;

    /**
     * 联系方式
     */
    private Contact contact = new Contact("绛门科技", "http://www.redoornetwork.com/views/index.html", "redoor@redoornetwork.com");

    /**
     * 扩展属性
     */
    private List<VendorExtension> vendorExtensions;

}
